import request from '@/utils/request'

// 查询参数列表
export function listCategory(query) {
  return request({
    url: '/ams/category/list',
    method: 'get',
    params: query
  })
}

// 查询参数详细
export function getCategory(categoryId) {
  return request({
    url: '/ams/category/' + categoryId,
    method: 'get'
  })
}


// 新增参数配置
export function addCategory(data) {
  return request({
    url: '/ams/category',
    method: 'post',
    data: data
  })
}

// 修改参数配置
export function updateCategory(data) {
  return request({
    url: '/ams/category',
    method: 'put',
    data: data
  })
}

// 删除参数配置
export function delCategory(data) {
  return request({
    url: '/ams/category',
    method: 'delete',
    data: data
  })
}

// 修改状态
export function changeCategoryStatus(data) {
  return request({
    url: '/ams/category/status',
    method: 'put',
    data: data
  })
}
